home *** CD-ROM | disk | FTP | other *** search
/ Especial Multimedia / Especial Multimedia.iso / Multimed / Herra / SLANG10.ZIP / CALC.VEC < prev    next >
Text File  |  1997-09-14  |  314b  |  21 lines

  1. print "SLANG calculator example"; "quit to exit";
  2. #start
  3. s = "3"
  4. x = 1
  5. input "Input expression: ", s
  6. if strchr(s, "quit")  then goto finish endif
  7.  
  8. str = " "
  9. if strchr(s, "=") = 0 then
  10.     puttoken(str, "x = ")
  11.     puttoken(str, s)
  12. endif
  13.  
  14. splay(str)
  15. print "x = ", x;
  16.  
  17. goto start
  18.  
  19. #finish            
  20. end
  21.